
def run(params:list[str]):
    try:
        from ApiTools import apiTools,apiBase
        #文件夹名称
        dirs=apiBase.argv_array(params,1,'/home/softrobot/llm/qwne05/txt/测试.txt;',';')
        delimiters = apiBase.argv(params,2,'\n')
        vectdb = apiTools.load_vec()
        for dir in dirs:
            vectdb.dir_upsert_dir(dir,delimiters)
        return 'load file ok'
        #ret = vectdb.askDirs(dataDir,None,"小红薯好吃吗?","file")
        #print(ret)
        #print(ret)
    except Exception as e:
        return f"function error:{e}"

#run([])